#include "Flare.h"

// XML flare plus initialisation
Flare::Flare()
	: Spell("Flare", "flare", "damage", "Assets/Artworks/Spells/Flare/Flare.png")
	, currentFlareWidth(0)
{
}

Flare::~Flare()
{
}

const float Flare::GetCurrentFlareWidth()
{
	return currentFlareWidth;
}

int Flare::SetCurrentFlareWidth(float increment, float setValue, bool needIncrement)
{
	if(needIncrement)
	{
		currentFlareWidth += increment;
	}
	else
	{		
		currentFlareWidth = setValue;
	}
	return (int)currentFlareWidth;
}

void Flare::Cast(int value, Character caster, Character target)
{
	target.Damage(value);
}

void Flare::Cast(int value, Character caster, Character targets[], int chars)
{
	for(int i = 0; i < chars; i++)
	{
		targets[i].Damage(value);
	}
}